home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 2000 July: Mac OS SDK / Dev.CD Jul 00 SDK2.toast / Development Kits / Cross Platform / QuickTime 4.1.2 Windows SDK / CIncludes / QTSMovie.h < prev    next >
Encoding:
C/C++ Source or Header  |  2000-04-12  |  4.8 KB  |  191 lines  |  [TEXT/R*ch]

  1. /*
  2.      File:        QTSMovie.h
  3.  
  4.      Contains:    QuickTime interfaces
  5.  
  6.      Version:    Technology:    
  7.                  Release:    QuickTime 4.1
  8.  
  9.      Copyright:    (c) 1990-1999 by Apple Computer, Inc., all rights reserved
  10.  
  11.      Bugs?:        For bug reports, consult the following page on
  12.                  the World Wide Web:
  13.  
  14.                      http://developer.apple.com/bugreporter/
  15.  
  16. */
  17. #ifndef __QTSMOVIE__
  18. #define __QTSMOVIE__
  19.  
  20. #ifndef __COMPONENTS__
  21.     #include <Components.h>
  22. #endif
  23.  
  24. #ifndef __MOVIES__
  25.     #include <Movies.h>
  26. #endif
  27.  
  28. #ifndef __QUICKTIMESTREAMING__
  29.     #include <QuickTimeStreaming.h>
  30. #endif
  31.  
  32.  
  33.  
  34.  
  35. #if PRAGMA_ONCE
  36. #pragma once
  37. #endif
  38.  
  39. #ifdef __cplusplus
  40. extern "C" {
  41. #endif
  42.  
  43. #if PRAGMA_IMPORT
  44. #pragma import on
  45. #endif
  46.  
  47. #if PRAGMA_STRUCT_ALIGN
  48.     #pragma options align=mac68k
  49. #elif PRAGMA_STRUCT_PACKPUSH
  50.     #pragma pack(push, 2)
  51. #elif PRAGMA_STRUCT_PACK
  52.     #pragma pack(2)
  53. #endif
  54.  
  55. enum {
  56.     kQTSStreamMediaType            = FOUR_CHAR_CODE('strm')
  57. };
  58.  
  59.  
  60. struct QTSSampleDescription {
  61.     long                             descSize;
  62.     long                             dataFormat;
  63.     long                             resvd1;                        /* set to 0*/
  64.     short                             resvd2;                        /* set to 0*/
  65.     short                             dataRefIndex;
  66.     UInt32                             version;
  67.     UInt32                             resvd3;                        /* set to 0*/
  68.     SInt32                             flags;
  69.                                                                 /* qt atoms follow:*/
  70.                                                                 /*         long size, long type, some data*/
  71.                                                                 /*         repeat as necessary*/
  72. };
  73. typedef struct QTSSampleDescription        QTSSampleDescription;
  74. typedef QTSSampleDescription *            QTSSampleDescriptionPtr;
  75. typedef QTSSampleDescriptionPtr *        QTSSampleDescriptionHandle;
  76. enum {
  77.     kQTSSampleDescriptionVersion1 = 1L
  78. };
  79.  
  80. enum {
  81.     kQTSDefaultMediaTimeScale    = 600L
  82. };
  83.  
  84. /* sample description flags*/
  85. enum {
  86.     kQTSSampleDescPassSampleDataAsHandleFlag = 0x00000001
  87. };
  88.  
  89.  
  90. /*============================================================================
  91.         Stream Media Handler
  92. ============================================================================*/
  93. /*-----------------------------------------
  94.     Info Selectors
  95. -----------------------------------------*/
  96. /* all indexes start at 1 */
  97.  
  98. enum {
  99.     kQTSMediaPresentationInfo    = FOUR_CHAR_CODE('pres'),        /* QTSMediaPresentationParams* */
  100.     kQTSMediaNotificationInfo    = FOUR_CHAR_CODE('noti'),        /* QTSMediaNotificationParams* */
  101.     kQTSMediaTotalDataRateInfo    = FOUR_CHAR_CODE('dtrt'),        /* UInt32*, bits/sec */
  102.     kQTSMediaLostPercentInfo    = FOUR_CHAR_CODE('lspc'),        /* Fixed* */
  103.     kQTSMediaNumStreamsInfo        = FOUR_CHAR_CODE('nstr'),        /* UInt32* */
  104.     kQTSMediaIndSampleDescriptionInfo = FOUR_CHAR_CODE('isdc')    /* QTSMediaIndSampleDescriptionParams* */
  105. };
  106.  
  107.  
  108.  
  109. struct QTSMediaPresentationParams {
  110.     QTSPresentation                 presentationID;
  111. };
  112. typedef struct QTSMediaPresentationParams QTSMediaPresentationParams;
  113.  
  114. struct QTSMediaNotificationParams {
  115.     QTSNotificationUPP                 notificationProc;
  116.     void *                            notificationRefCon;
  117.     SInt32                             flags;
  118. };
  119. typedef struct QTSMediaNotificationParams QTSMediaNotificationParams;
  120.  
  121. struct QTSMediaIndSampleDescriptionParams {
  122.     SInt32                             index;
  123.     OSType                             returnedMediaType;
  124.     SampleDescriptionHandle         returnedSampleDescription;
  125. };
  126. typedef struct QTSMediaIndSampleDescriptionParams QTSMediaIndSampleDescriptionParams;
  127. /*-----------------------------------------
  128.     QTS Media Handler Selectors
  129. -----------------------------------------*/
  130. enum {
  131.     kQTSMediaSetInfoSelect        = 0x0100,
  132.     kQTSMediaGetInfoSelect        = 0x0101,
  133.     kQTSMediaSetIndStreamInfoSelect = 0x0102,
  134.     kQTSMediaGetIndStreamInfoSelect = 0x0103
  135. };
  136.  
  137. /*-----------------------------------------
  138.     QTS Media Handler functions
  139. -----------------------------------------*/
  140. EXTERN_API( ComponentResult )
  141. QTSMediaSetInfo                    (MediaHandler             mh,
  142.                                  OSType                 inSelector,
  143.                                  void *                    ioParams)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0100, 0x7000, 0xA82A);
  144.  
  145. EXTERN_API( ComponentResult )
  146. QTSMediaGetInfo                    (MediaHandler             mh,
  147.                                  OSType                 inSelector,
  148.                                  void *                    ioParams)                            FIVEWORDINLINE(0x2F3C, 0x0008, 0x0101, 0x7000, 0xA82A);
  149.  
  150. EXTERN_API( ComponentResult )
  151. QTSMediaSetIndStreamInfo        (MediaHandler             mh,
  152.                                  SInt32                 inIndex,
  153.                                  OSType                 inSelector,
  154.                                  void *                    ioParams)                            FIVEWORDINLINE(0x2F3C, 0x000C, 0x0102, 0x7000, 0xA82A);
  155.  
  156. EXTERN_API( ComponentResult )
  157. QTSMediaGetIndStreamInfo        (MediaHandler             mh,
  158.                                  SInt32                 inIndex,
  159.                                  OSType                 inSelector,
  160.                                  void *                    ioParams)                            FIVEWORDINLINE(0x2F3C, 0x000C, 0x0103, 0x7000, 0xA82A);
  161.  
  162.  
  163. /* MixedMode ProcInfo constants for component calls */
  164. enum {
  165.     uppQTSMediaSetInfoProcInfo                        = 0x00000FF0,
  166.     uppQTSMediaGetInfoProcInfo                        = 0x00000FF0,
  167.     uppQTSMediaSetIndStreamInfoProcInfo                = 0x00003FF0,
  168.     uppQTSMediaGetIndStreamInfoProcInfo                = 0x00003FF0
  169. };
  170.  
  171. #if PRAGMA_STRUCT_ALIGN
  172.     #pragma options align=reset
  173. #elif PRAGMA_STRUCT_PACKPUSH
  174.     #pragma pack(pop)
  175. #elif PRAGMA_STRUCT_PACK
  176.     #pragma pack()
  177. #endif
  178.  
  179. #ifdef PRAGMA_IMPORT_OFF
  180. #pragma import off
  181. #elif PRAGMA_IMPORT
  182. #pragma import reset
  183. #endif
  184.  
  185. #ifdef __cplusplus
  186. }
  187. #endif
  188.  
  189. #endif /* __QTSMOVIE__ */
  190.  
  191.